<!DOCTYPE html>
<html>
  <head>
    <title></title>
    <!-- <link rel='stylesheet' href='/stylesheets/style.css' /> -->
    <link rel="stylesheet" href="/stylesheets/index.css">
  </head>
  <body>
    <!-- <div class="container">
      <header>
          <h1>DEMO1</h1>
      </header>
      <nav>
        <a href="/">首页</a>
        <a href="/product">产品</a>
        <a href="/article">文章</a>
        <a href="#">留言</a>
      </nav> -->
      <% include header.ejs %>
    <div class="box">
      <div class="left">
        <% if(articles && articles.length>0){ %>
          <% for(article of articles){ %>
            <a href="/article/article/<%=article.id%>"><%=article.title%></a>
            <p><%=article.text%></p>
          <% } %>

        <% } %>
      </div>
      <div class="main">
        <div class="product-list">
          <% if(products && products.length>0){%>
            <% for(product of products){%>
              <div class="product">
                <h3><%=product.name%></h3>
                <img src="/admin/img/<%=product.file.filename%>" alt="">
                <p>price: <span><%=product.price%></span>￥</p>
              </div>
            <% } %>
          <%} %>
        </div>
      </div>

    </div>
      <footer>
        <p>@xxxxxxx</p>
      </footer>
    </div>
  </body>
</html>
